home *** CD-ROM | disk | FTP | other *** search
- unit Message;
-
- interface
-
- procedure A_Message (s0, s1, s2, s3: str255; var theItem: integer);
-
- implementation
-
- procedure A_Message;
- var
- itemHit: Integer;
- AlertResHandle: AlertTHndl;
- tempRect: Rect;
-
- begin {Start of alert handler}
- ParamText(s0, s1, s2, s3);
- AlertResHandle := AlertTHndl(GetResource('ALRT', 4));
- HLock(Handle(AlertResHandle));
- tempRect := AlertResHandle^^.boundsRect;
- tempRect.Left := ((screenBits.Bounds.Right - screenBits.Bounds.Left) - (tempRect.Right - tempRect.Left)) div 2;{Center Horz}
- tempRect.Bottom := tempRect.Top + (AlertResHandle^^.boundsRect.Bottom - AlertResHandle^^.boundsRect.Top);
- tempRect.Right := tempRect.Left + (AlertResHandle^^.boundsRect.Right - AlertResHandle^^.boundsRect.Left);
- AlertResHandle^^.boundsRect := tempRect;
-
- theItem := NoteAlert(4, nil);
- HUnLock(Handle(AlertResHandle));
-
- end; {End of procedure}
-
- end. {End of unit}